home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1997 January: Mac OS SDK / Dev.CD Jan 97 SDK2.toast / Development Kits (Disc 2) / OpenDoc Development Framework / ODF-Interest Archive / June 96 / Re creating a view as window⁄f < prev    next >
Encoding:
Internet Message Format  |  1996-12-03  |  1.8 KB  |  [TEXT/ttxt]

  1. Subject:     Re: creating a view as window/frame/view
  2. Sent:        6/6/96 2:31 PM
  3. Received:    6/6/96 2:51 PM
  4. From:        Henri Lamiraux, lamiraux@apple.com
  5. Reply-To:    ODF Interest, ODF-Interest@CILabs.ORG
  6. To:          OpenDoc Development Framework Discussion List, ODF-Interest@CILabs.
  7.  
  8. >My part needs to open up an additional window with scroll bars, but I can't
  9. >find any good example recipies. 
  10. >
  11. >My OpenDoc part is a graphing part, and I want to allow the user to open up
  12. >a window to show the data in a speadsheet style view with scroll bars, and
  13. >close box.
  14. >
  15. >I can find good example recipies for floating windows but nothing for what
  16. >I want to do. In the FW_CFloatingWindow examples that I have seen they
  17. >always create their own window using FW_NEW, but in FWWindow.h it says -
  18. >"You should never directly create a FW_CWindow, ODF will create it for
  19. >you". - does this rule not apply to floating windows?
  20. >
  21. >Thanks for any help,
  22. >Neal Williams
  23. >Corda Technologies, Inc.
  24.  
  25. What you want to do is what the 'View In Window' command does. If you 
  26. want to have your own menu command the easiest way to do that is to 
  27. directly call myFrame->GetPresentation(ev)->OpenPartWindow(...). The 
  28. facet parameter can be null. By default the root frame of the new window 
  29. will have the same presentation has the source frame. To change that 
  30. override FW_CFrame:NewPartWindow and pass the right presentation to the 
  31. constructor of FW_CWindow.
  32.  
  33. Limitation: ODF currently allows only one secondary window. This will be 
  34. fixed in a future release.
  35.  
  36. ........................................................................
  37.  Henri Lamiraux                                      lamiraux@apple.com
  38.  Apple Computer, Inc.                 OpenDoc(tm) Development Framework
  39. ........................................................................
  40.  
  41.